package com.wentao.mall.dao

import com.wentao.mall.api.BuyerOrder
import com.wentao.mall.api.OrderStatus
import org.springframework.data.jpa.repository.JpaRepository

interface OrderDao : JpaRepository<BuyerOrder, Int> {
    fun findByOpenId(openId: String): List<BuyerOrder>
    fun findByOpenIdAndStatus(openId: String, status: OrderStatus): List<BuyerOrder>
    fun findByOpenIdAndMerchantId(openId: String, merchantId: Int): List<BuyerOrder>
}